<?php

namespace app\index\controller;

use think\Controller;
use app\index\model\User;

class TestModel extends Controller
{
    protected $userModel;

    public function initialize ()
    {
        $this->userModel = new User();
    }
    
    public function test ()
    {
        $data = [
            't_name'   =>  'kaka1',
            't_age'    =>  24,
            't_time'   => time()
        ];
        $this->userModel->save($data);
    }
}
